3.401 \(\int \cos ^3(c+d x) (a+b \sin (c+d x))^3 \, dx\)

Optimal. Leaf size=77 \[ -\frac{\left (a^2-b^2\right ) (a+b \sin (c+d x))^4}{4 b^3 d}-\frac{(a+b \sin (c+d x))^6}{6 b^3 d}+\frac{2 a (a+b \sin (c+d x))^5}{5 b^3 d} \]

[Out]

-((a^2 - b^2)*(a + b*Sin[c + d*x])^4)/(4*b^3*d) + (2*a*(a + b*Sin[c + d*x])^5)/(5*b^3*d) - (a + b*Sin[c + d*x]
)^6/(6*b^3*d)

________________________________________________________________________________________

Rubi [A]  time = 0.0802826, antiderivative size = 77, normalized size of antiderivative = 1., number of steps used = 3, number of rules used = 2, integrand size = 21, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.095, Rules used = {2668, 697} \[ -\frac{\left (a^2-b^2\right ) (a+b \sin (c+d x))^4}{4 b^3 d}-\frac{(a+b \sin (c+d x))^6}{6 b^3 d}+\frac{2 a (a+b \sin (c+d x))^5}{5 b^3 d} \]

Antiderivative was successfully verified.

[In]

Int[Cos[c + d*x]^3*(a + b*Sin[c + d*x])^3,x]

[Out]

-((a^2 - b^2)*(a + b*Sin[c + d*x])^4)/(4*b^3*d) + (2*a*(a + b*Sin[c + d*x])^5)/(5*b^3*d) - (a + b*Sin[c + d*x]
)^6/(6*b^3*d)

Rule 2668

Int[cos[(e_.) + (f_.)*(x_)]^(p_.)*((a_) + (b_.)*sin[(e_.) + (f_.)*(x_)])^(m_.), x_Symbol] :> Dist[1/(b^p*f), S
ubst[Int[(a + x)^m*(b^2 - x^2)^((p - 1)/2), x], x, b*Sin[e + f*x]], x] /; FreeQ[{a, b, e, f, m}, x] && Integer
Q[(p - 1)/2] && NeQ[a^2 - b^2, 0]

Rule 697

Int[((d_) + (e_.)*(x_))^(m_)*((a_) + (c_.)*(x_)^2)^(p_.), x_Symbol] :> Int[ExpandIntegrand[(d + e*x)^m*(a + c*
x^2)^p, x], x] /; FreeQ[{a, c, d, e, m}, x] && NeQ[c*d^2 + a*e^2, 0] && IGtQ[p, 0]

Rubi steps

\begin{align*} \int \cos ^3(c+d x) (a+b \sin (c+d x))^3 \, dx &=\frac{\operatorname{Subst}\left (\int (a+x)^3 \left (b^2-x^2\right ) \, dx,x,b \sin (c+d x)\right )}{b^3 d}\\ &=\frac{\operatorname{Subst}\left (\int \left (\left (-a^2+b^2\right ) (a+x)^3+2 a (a+x)^4-(a+x)^5\right ) \, dx,x,b \sin (c+d x)\right )}{b^3 d}\\ &=-\frac{\left (a^2-b^2\right ) (a+b \sin (c+d x))^4}{4 b^3 d}+\frac{2 a (a+b \sin (c+d x))^5}{5 b^3 d}-\frac{(a+b \sin (c+d x))^6}{6 b^3 d}\\ \end{align*}

Mathematica [A]  time = 0.148069, size = 56, normalized size = 0.73 \[ \frac{(a+b \sin (c+d x))^4 \left (-a^2+4 a b \sin (c+d x)+5 b^2 \cos (2 (c+d x))+10 b^2\right )}{60 b^3 d} \]

Antiderivative was successfully verified.

[In]

Integrate[Cos[c + d*x]^3*(a + b*Sin[c + d*x])^3,x]

[Out]

((a + b*Sin[c + d*x])^4*(-a^2 + 10*b^2 + 5*b^2*Cos[2*(c + d*x)] + 4*a*b*Sin[c + d*x]))/(60*b^3*d)

________________________________________________________________________________________

Maple [A]  time = 0.055, size = 115, normalized size = 1.5 \begin{align*}{\frac{1}{d} \left ({b}^{3} \left ( -{\frac{ \left ( \sin \left ( dx+c \right ) \right ) ^{2} \left ( \cos \left ( dx+c \right ) \right ) ^{4}}{6}}-{\frac{ \left ( \cos \left ( dx+c \right ) \right ) ^{4}}{12}} \right ) +3\,a{b}^{2} \left ( -1/5\,\sin \left ( dx+c \right ) \left ( \cos \left ( dx+c \right ) \right ) ^{4}+1/15\, \left ( 2+ \left ( \cos \left ( dx+c \right ) \right ) ^{2} \right ) \sin \left ( dx+c \right ) \right ) -{\frac{3\,{a}^{2}b \left ( \cos \left ( dx+c \right ) \right ) ^{4}}{4}}+{\frac{{a}^{3} \left ( 2+ \left ( \cos \left ( dx+c \right ) \right ) ^{2} \right ) \sin \left ( dx+c \right ) }{3}} \right ) } \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

int(cos(d*x+c)^3*(a+b*sin(d*x+c))^3,x)

[Out]

1/d*(b^3*(-1/6*sin(d*x+c)^2*cos(d*x+c)^4-1/12*cos(d*x+c)^4)+3*a*b^2*(-1/5*sin(d*x+c)*cos(d*x+c)^4+1/15*(2+cos(
d*x+c)^2)*sin(d*x+c))-3/4*a^2*b*cos(d*x+c)^4+1/3*a^3*(2+cos(d*x+c)^2)*sin(d*x+c))

________________________________________________________________________________________

Maxima [A]  time = 0.965449, size = 135, normalized size = 1.75 \begin{align*} -\frac{10 \, b^{3} \sin \left (d x + c\right )^{6} + 36 \, a b^{2} \sin \left (d x + c\right )^{5} - 90 \, a^{2} b \sin \left (d x + c\right )^{2} + 15 \,{\left (3 \, a^{2} b - b^{3}\right )} \sin \left (d x + c\right )^{4} - 60 \, a^{3} \sin \left (d x + c\right ) + 20 \,{\left (a^{3} - 3 \, a b^{2}\right )} \sin \left (d x + c\right )^{3}}{60 \, d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^3*(a+b*sin(d*x+c))^3,x, algorithm="maxima")

[Out]

-1/60*(10*b^3*sin(d*x + c)^6 + 36*a*b^2*sin(d*x + c)^5 - 90*a^2*b*sin(d*x + c)^2 + 15*(3*a^2*b - b^3)*sin(d*x
+ c)^4 - 60*a^3*sin(d*x + c) + 20*(a^3 - 3*a*b^2)*sin(d*x + c)^3)/d

________________________________________________________________________________________

Fricas [A]  time = 2.25355, size = 221, normalized size = 2.87 \begin{align*} \frac{10 \, b^{3} \cos \left (d x + c\right )^{6} - 15 \,{\left (3 \, a^{2} b + b^{3}\right )} \cos \left (d x + c\right )^{4} - 4 \,{\left (9 \, a b^{2} \cos \left (d x + c\right )^{4} - 10 \, a^{3} - 6 \, a b^{2} -{\left (5 \, a^{3} + 3 \, a b^{2}\right )} \cos \left (d x + c\right )^{2}\right )} \sin \left (d x + c\right )}{60 \, d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^3*(a+b*sin(d*x+c))^3,x, algorithm="fricas")

[Out]

1/60*(10*b^3*cos(d*x + c)^6 - 15*(3*a^2*b + b^3)*cos(d*x + c)^4 - 4*(9*a*b^2*cos(d*x + c)^4 - 10*a^3 - 6*a*b^2
 - (5*a^3 + 3*a*b^2)*cos(d*x + c)^2)*sin(d*x + c))/d

________________________________________________________________________________________

Sympy [A]  time = 4.58979, size = 178, normalized size = 2.31 \begin{align*} \begin{cases} \frac{2 a^{3} \sin ^{3}{\left (c + d x \right )}}{3 d} + \frac{a^{3} \sin{\left (c + d x \right )} \cos ^{2}{\left (c + d x \right )}}{d} + \frac{3 a^{2} b \sin ^{4}{\left (c + d x \right )}}{4 d} + \frac{3 a^{2} b \sin ^{2}{\left (c + d x \right )} \cos ^{2}{\left (c + d x \right )}}{2 d} + \frac{2 a b^{2} \sin ^{5}{\left (c + d x \right )}}{5 d} + \frac{a b^{2} \sin ^{3}{\left (c + d x \right )} \cos ^{2}{\left (c + d x \right )}}{d} + \frac{b^{3} \sin ^{6}{\left (c + d x \right )}}{12 d} + \frac{b^{3} \sin ^{4}{\left (c + d x \right )} \cos ^{2}{\left (c + d x \right )}}{4 d} & \text{for}\: d \neq 0 \\x \left (a + b \sin{\left (c \right )}\right )^{3} \cos ^{3}{\left (c \right )} & \text{otherwise} \end{cases} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)**3*(a+b*sin(d*x+c))**3,x)

[Out]

Piecewise((2*a**3*sin(c + d*x)**3/(3*d) + a**3*sin(c + d*x)*cos(c + d*x)**2/d + 3*a**2*b*sin(c + d*x)**4/(4*d)
 + 3*a**2*b*sin(c + d*x)**2*cos(c + d*x)**2/(2*d) + 2*a*b**2*sin(c + d*x)**5/(5*d) + a*b**2*sin(c + d*x)**3*co
s(c + d*x)**2/d + b**3*sin(c + d*x)**6/(12*d) + b**3*sin(c + d*x)**4*cos(c + d*x)**2/(4*d), Ne(d, 0)), (x*(a +
 b*sin(c))**3*cos(c)**3, True))

________________________________________________________________________________________

Giac [A]  time = 1.10707, size = 151, normalized size = 1.96 \begin{align*} -\frac{10 \, b^{3} \sin \left (d x + c\right )^{6} + 36 \, a b^{2} \sin \left (d x + c\right )^{5} + 45 \, a^{2} b \sin \left (d x + c\right )^{4} - 15 \, b^{3} \sin \left (d x + c\right )^{4} + 20 \, a^{3} \sin \left (d x + c\right )^{3} - 60 \, a b^{2} \sin \left (d x + c\right )^{3} - 90 \, a^{2} b \sin \left (d x + c\right )^{2} - 60 \, a^{3} \sin \left (d x + c\right )}{60 \, d} \end{align*}

Verification of antiderivative is not currently implemented for this CAS.

[In]

integrate(cos(d*x+c)^3*(a+b*sin(d*x+c))^3,x, algorithm="giac")

[Out]

-1/60*(10*b^3*sin(d*x + c)^6 + 36*a*b^2*sin(d*x + c)^5 + 45*a^2*b*sin(d*x + c)^4 - 15*b^3*sin(d*x + c)^4 + 20*
a^3*sin(d*x + c)^3 - 60*a*b^2*sin(d*x + c)^3 - 90*a^2*b*sin(d*x + c)^2 - 60*a^3*sin(d*x + c))/d